<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<head th:include="common/common :: jscss2">
    <title>目标管理</title>

</head>
<body>
<style>
    .mt8 {
        margin-top: 8px;
    }
</style>
<div class="layui-fluid">
    <blockquote class="layui-crumb">
        &nbsp;&nbsp;<a>模板导入</a>
    </blockquote>
    <div class="layui-card">


        <!--<form method="post" action="" class="layui-form" lay-filter="zmn-form">-->
        <form class="layui-form" enctype="multipart/form-data">
            <div class="layui-card-header" style="margin-top:10px;"><b>导入文件</b></div>
            <div class="layui-split">&nbsp;</div>
            <div class="layui-form-item">
                <label class="layui-form-label layui-form-required">Excel文件：</label>
                <button type="button" class="layui-btn layui-btn-normal" id="importData"><i
                        class="layui-icon">&#xe67c;</i>选择文件
                </button>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label"></label>
                <div>
                    <div class="layui-form-mid ">
                        只能上传excel文件，文件表格内容请保留首行标题，请勿改变模板格式，一次性最多支持上传<span style="color: red">1000</span>条数据。
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label"></label>
                <div>
                    <div class="layui-form-mid  " id="divMsg" style="color: red">
                    </div>
                </div>
            </div>
            <div class="layui-form-item ">
                <div class="layui-input-block">
                    <button type="button" class="layui-btn" id="submitExcel">提交</button>
                    <button class="layui-btn layui-btn-primary" id="cancleBtn"
                            onclick="layui.admin.events.closeThisTabs();">
                        取消
                    </button>
                </div>
            </div>
            <div class="layui-split">&nbsp;</div>
        </form>
    </div>
</div>

<script type="text/javascript" th:inline="javascript">
    function wordStatic(input, id) {
        var currentInput = document.getElementsByName(id)[0];
        currentInput.value = currentInput.value.replace(/[^\u4E00-\u9FA5]/g, '');
        var content = document.getElementById(id);
        if (content && input) {
            var value = input.value.replace(/\\n|\\r/gi, '');
            content.innerText = value.length;
        }
    }
</script>

<script type="text/javascript" th:inline="javascript">
    var json = {
        obj: [[${obj}]],
    };
    layui.config({
        base: "/static/lay/"
    }).extend({
        index: "lib/index",
        zmn_plat_phenomenon_excel_edit: "base/phenomenon/zmn.plat.phenomenon.excel.edit",
    }).use(['index', 'zmn_plat_phenomenon_excel_edit']);
</script>
</body>
</html>